package com.flyco.modules.stm.service;

import com.flyco.modules.stm.entity.StmStoreProductStock;
import com.baomidou.mybatisplus.extension.service.IService;

/**
 * @Description: 门店商品库存表
 * @Author: flyco
 * @Date:   2024-01-03
 * @Version: V1.0
 */
public interface IStmStoreProductStockService extends IService<StmStoreProductStock> {

    /**
     * 一次性把历史订单数据初始化到库存表中
     */
    void init();

    //订单审核通过或退货时调用，退货是productQty要为负数
    void updateStock(Long storeId, Long productId, Integer productQty);

}
